<!--S公共头部-->
<include file="Public/security_head"/>
<!--E公共头部-->
<style>
    #sflex04{
        width: 540px;
    }

</style>
<div class="w990">
    <div id="find-pw3">
        <div class="find-con">

            <!--			绑定邮箱-->
            <div id="find-box" class="uc-box page_a">
                <div style="width: 200px;height: 100px;"></div>
                <div class="find-pwd-con">
                    <form action="{:U('emil_a')}" method="post" id="password_a" name="password_a" novalidate="novalidate">
                        <input type="hidden" name="page" value="1">
                        <div id="error_container"></div>
                        <div class="item">
                            <label>&nbsp&nbsp&nbsp邮箱</label>
                            <input name="user_email" id="user_email" type="text" tabindex="1" placeholder="请输入您邮箱" class="text">
                        </div>
                        <div class="item">
                            <label>验证码</label>
                            <input type="text" id="captcha" name="emil_code" tabindex="2" placeholder="请输入验证码" autocomplete="off" class="text text-te">
                            <label class="img" style="margin-left: 5px"><input id="zphone" type="button" style="width: 79px;height: 36px;background-color:#E31939;color:#fff;border: 0px;" value="发送验证码" onclick="Send_emil()"/></label>
                        </div>
                        <div class="item">
                            <label></label>
                            <input type="submit" id="btn_submit" class="btn_next" value="下一步">
                        </div>
                        <div class="item">
                            <h2 class="find_pw_tit"><span>绑定邮箱提高账户安全，方便即时找回密码</span></h2>
                        </div>
                    </form>
                </div>
                <script>
                    $('#password_a').layer({});
                </script>
            </div>

    </div>
</div>


<!--S公共尾部-->
<include file="Public/security_bottom"/>
<!--E公共尾部-->

    <script>

        function Send_emil(){
            user_email = $("#user_email").val();
            if(!user_email){
                layer.msg("您还没有输入邮箱地址");
                return;
            }
            CheckMail(user_email);
        }
        function CheckMail(mail) {
            var filter  = /^([a-zA-Z0-9_\.\-])+\@(([a-zA-Z0-9\-])+\.)+([a-zA-Z0-9]{2,4})+$/;
            if (filter.exec(mail)){
                layer.msg("验证码已发送至邮箱");
                RemainTime("发送验证码");
                var data = {user_email:user_email};
                $.ajax({
                    type: "POST",
                    url: homeUrl+"/Security/emil",
                    data: data,
                    dataType: "json"
                });
            }
            else {
                layer.msg("您还没有输入邮箱地址");
            }
        }
    </script>


